Save User Point Reddem History
POST : http://<base_url>/digipay/v3/reward_promotion/user_points_redeem
This API Allows developers to record and store information about user point redemptions within the system. This API is a crucial part of managing user rewards and maintaining transparency in the points-based ecosystem. It enables the system to keep track of user interactions, redemptions, and associated details.
BODY PARAMS:-
Parameter | Type | Description | Value |
---|---|---|---|
user_id | String | unique id of user who is redeem the earned reward/referral points | b9a4cbeeedd340509cb1ac628cae2973 |
points | Double | points redeemd by user | 100 |
transaction_id | String | unique id of transaction on which user will redeem the points | b9a4cbeeedd340509cb1ac628cae2973 |
amount | Double | amount earned after redeem the reward/referral points | 100 |
description | String | a description note related to transaction | test |
currency_id | String | unique id of currency in which user is earning the redeemed points | b9a4cbeeedd340509cb1ac628cae2973 |
reward_program_id | String | unique id of reward_program for which user is earning the redeemed points | b9a4cbeeedd340509cb1ac628cae2973 |
HEADERS:-
Parameter | Type | Description | Value |
---|---|---|---|
Authorization | String | It is a combination of type and token to authenticate user for the given token | Token duik7309njdlkhdauhknksadhjkas986876sd873j |
CompanyID | String | Company_id is a unique primary id, that is represent company detail | 76bc712200ca444fa334f9e55e5fd7a8 |
Request Body:-
Request Example
curl --request POST \
--url http://192.168.1.102:8014/digipay/v3/reward_promotion/user_points_redeem \
--header 'Authorization: Token duik7309njdlkhdauhknksadhjkas986876sd873j' \
--header 'CompanyID: 7753ad6bd8cf48f5b1312fd21eb36588' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"user_id": "b9a4cbeeedd340509cb1ac628cae2973",
"points": 10,
"transaction_id": "b9a4cbeeedd340509cb1ac628cae2973",
"amount": 100,
"description": "test",
"currency_id": "b9a4cbeeedd340509cb1ac628cae2973",
"reward_program_id": "b9a4cbeeedd340509cb1ac628cae2973"
}
'
Response:-
Response 200(OK)
{
"success": 1,
"error": [],
"data": {
"message": "User Points Redeem saved successfully.",
"user_points_redeem_id": "4428647ee7ed420487cd6899f51eaa63"
}
}
Response 400(BAD REQUEST)
{
"success": 0,
"error"": [1],
"data": {
"message": "BAD_REQUEST",
}
}
RESPONSES :-
Status Code | Description |
---|---|
200 | OK |
400 | BAD REQUEST |
404 | NOT FOUND |
500 | INTERNAL SERVER ERROR |